package com.ce.pms.log4ce;

import java.util.Map;

import org.aspectj.lang.JoinPoint;

import com.ce.component.log4ce.aop.constructor.support.AbstractOriginalObjectHolder;
import com.ce.component.log4ce.aop.constructor.support.OriginalObjectHolder;
import com.ce.component.log4ce.aop.parser.BizLogParser;
import com.ce.pms.house.vo.FlatVO;

public class HouseEditHolder extends AbstractOriginalObjectHolder implements OriginalObjectHolder {
	private Log4ceHelper log4ceHelper = Log4ceHelper.getInstance();
	@Override
	protected Map<String, Object> getOriginalObjects(JoinPoint joinPoint, BizLogParser logParser) {
		
		Map<String,Object> map = logParser.getLogArguments(joinPoint);

		//获取被代理方法的参数
		FlatVO flatvo = (FlatVO) map.get("flatvo");
		
		FlatVO housevo = log4ceHelper.getFlatVOById(flatvo.getKeyword());
		map.put("oldHouseInfo", housevo);
		
		return map;
	}
	
}
